package cn.datawin.sms.enums;

import org.apache.commons.lang3.StringUtils;

/**
 * 通讯协议
 */
public enum ProtocolType {

    CMPP2,

    CMPP3;

    private String value;

    private ProtocolType() {
        this.value = this.name().toLowerCase();
    }

    @Override
    public String toString() {
        return value;
    }

    public boolean equals(String value) {
        if (StringUtils.isEmpty(value)) {
            return false;
        }
        return this.value.equalsIgnoreCase(value);
    }
}
